package com.jeasonzhao.commons.json;

import com.jeasonzhao.commons.parser.lex.LexToken;
import com.jeasonzhao.commons.parser.lex.LexTokenCollection;

public class JSONSpecial extends JSONNode
{
    private static final long serialVersionUID = 1L;
    private LexToken m_token = null;
    public JSONSpecial(String str)
    {
        this(LexToken.create(str));
    }

    public JSONSpecial(LexToken tk)
    {
        super(JSONNodeTypes.SPECIAL);
        m_token = tk;
        this.m_tokens = new LexTokenCollection();
        m_tokens.add(tk);
    }

    public String getValue()
    {
        return null == m_token ? null : m_token.getToken();
    }

    public String toJSON(boolean isFullMode,int nLevel)
    {
        return null == m_token ? null : m_token.getToken();
    }
}
